package com.project.dao;

import com.project.bean.PostBean;
import java.util.List;
import java.util.Map;

public interface PostMapper {
	//删除动态
    int deleteByPrimaryKey(Integer pId);
    //添加动态
    int insert(PostBean record);

    int insertSelective(PostBean record);

    PostBean selectByPrimaryKey(Integer pId);

    int updateByPrimaryKeySelective(PostBean record);

    int updateByPrimaryKey(PostBean record);

    int insertBatchSelective(List<PostBean> records);

    int updateBatchByPrimaryKeySelective(List<PostBean> records);
    

    //分页查询某个用户的动态
	List<PostBean> findPostsByPage(Map<String, Integer> map);
	
	//显示某个用户的动态数量
	int findAllByUid(Integer id);
	
	//查询某个用户的所有动态
	List<PostBean> findUserAllPosts(Integer id);
	
	//分页查询关注的动态
	List<PostBean> findFollowPostsByPage(Map<String, Object> map);
	




    
    
    
}